package com.lord.rowcopy.service.impl;

import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

import org.springframework.stereotype.Service;

import com.lord.rowcopy.service.RowcopyService;

/**
 * @Description: 审批表导出service实现类
 * @author Lord
 * @date 2022年01月19日
 */
@Service
public class RowcopyServiceImpl implements RowcopyService {

    /** 
     * <p>Title: getApprovalBusinessSheetData</p>
     * <p>Description: 审批表-生意贷</p> 
     * @return Map<String, Object>
     */
    @Override
    public Map<String, Object> getApprovalBusinessSheetData() {

        Map<String, Object> resultMap = new HashMap<>();
        List<Map<String, Object>> companyPartnerList = new ArrayList<>();
        List<Map<String, Object>> guarantorList = new ArrayList<>();
        List<Map<String, Object>> housePledgeList = new ArrayList<>();
        List<Map<String, Object>> carPledgeList = new ArrayList<>();
        List<Map<String, Object>> unionReviewList = new ArrayList<>();

        // 借款人基本情况
        resultMap.put("custInfoRealName", "张三");
        resultMap.put("custInfoAge", 28);
        resultMap.put("custInfoJob", "成功学大师");
        resultMap.put("custInfoTelephone", "13888888888");
        resultMap.put("mateInfoRealName", "王五");
        resultMap.put("mateInfoAge", 26);
        resultMap.put("mateInfoJob", "销售精英");
        resultMap.put("mateInfoTelephone", "13999999999");
        resultMap.put("companyInfoName", "精英培训管理有限公司");
        resultMap.put("companyInfoRegisterAddress", "陕西省西安市莲湖区");

        // 股东信息集合
        Map<String, Object> companyPartner1Map = new HashMap<>();
        companyPartner1Map.put("partnerName", "李四");
        companyPartner1Map.put("investAmount", "500000");
        companyPartner1Map.put("proportion", "10%");
        Map<String, Object> companyPartner2Map = new HashMap<>();
        companyPartner2Map.put("partnerName", "李五");
        companyPartner2Map.put("investAmount", "10000000");
        companyPartner2Map.put("proportion", "20%");
        companyPartnerList.add(companyPartner1Map);
        companyPartnerList.add(companyPartner2Map);
        resultMap.put("companyPartnerList", companyPartnerList);

        // 借款人基本情况
        resultMap.put("companyInfoBusinessAddress", "陕西省西安市高新区");
        resultMap.put("companyInfoRegisterAmount", 5000000);
        resultMap.put("custInfoHistoryWorkExperience",
                "1974年2月14日，张三出生于江苏省宿迁市来龙镇光明村，家境贫寒，父母以驶船为生，从小将他放在姥姥家，“姥姥不识字，从小到大一直都是自己做主”。");
        resultMap.put("custInfoCurrWorkExperience", "1992年，张三高中毕业于宿迁中学；同年，张三考上中国人民大学。");
        resultMap.put("companyInfoBusinessItem", "2014年3月10日，某东与腾讯联合宣布，腾讯入股某东，成为其一个重要股东。");
        resultMap.put("companyInfoProfitModel", "2016年10月13日，2016年胡润百富榜，张三以455亿财富排名第26位。");
        resultMap.put("custInfoOnceLoanExperience", "2016年11月，张三登上《福布斯杂志》封面。");
        resultMap.put("reviewOldCustManageScaleChange", "2014年3月10日，某东与腾讯联合宣布，腾讯入股某东，成为其一个重要股东。");
        resultMap.put("reviewOldCustManageProjChange", "2017年11月，提名全国工商联兼职副主席。");
        resultMap.put("reviewOldCustLiabilityChange", "2017年11月27日，当选中华全国工商业联合会副会长。");
        resultMap.put("reviewOldCustManageIncomeChange", "2017年11月28日，被聘为河北省阜平县龙泉关镇平石头村“名誉村主任”");

        // 借款人申请内容
        resultMap.put("applyAmount", 2000000);
        resultMap.put("applyPeriod", 10);
        resultMap.put("otherExplainInfoSource", "网络渠道");
        resultMap.put("otherExplainSurveyTime", "2022-01-19");
        resultMap.put("custInfoLoanUse", "经商");
        resultMap.put("custInfoRefundSource", "某东商城");

        // 借款人情况
        resultMap.put("ratingGrade", "D");
        resultMap.put("loanAmount", "A");
        resultMap.put("creditLimit", 2000000);
        resultMap.put("totalNetAssets", 500000);
        resultMap.put("totalAssets", 500000);
        resultMap.put("totalDebt", 500000);
        resultMap.put("totalAvgIncome", 500000);
        resultMap.put("avgNetIncome", 500000);
        resultMap.put("reviewCompanyJoinRelation", "暂无");
        resultMap.put("reviewCustExecutiveCondition", "暂无");
        resultMap.put("reviewCompanyDetail", "暂无");

        // 保证人情况
        Map<String, Object> guarantor1Map = new HashMap<>();
        guarantor1Map.put("name", "张一");
        guarantor1Map.put("cardNo", "622820xxxxxxxxxxxxxx");
        guarantor1Map.put("avgAmount", "10000");
        guarantor1Map.put("telephone", "15200000000");
        guarantor1Map.put("job", "测试");
        guarantor1Map.put("familyAddress", "不详");
        guarantor1Map.put("houseTotalNum", "1");
        guarantor1Map.put("houseTotalPrice", "5000000");
        guarantor1Map.put("carTotalNum", "1");
        guarantor1Map.put("carTotalPrice", "100000");
        guarantor1Map.put("otherDescription", "不详");
        guarantorList.add(guarantor1Map);

        Map<String, Object> guarantor2Map = new HashMap<>();
        guarantor2Map.put("name", "张二");
        guarantor2Map.put("cardNo", "622821xxxxxxxxxxxxxx");
        guarantor2Map.put("avgAmount", "8000");
        guarantor2Map.put("telephone", "15100000000");
        guarantor2Map.put("job", "研发");
        guarantor2Map.put("familyAddress", "不详");
        guarantor2Map.put("houseTotalNum", "1");
        guarantor2Map.put("houseTotalPrice", "2000000");
        guarantor2Map.put("carTotalNum", "1");
        guarantor2Map.put("carTotalPrice", "100000");
        guarantor2Map.put("otherDescription", "不详");
        guarantorList.add(guarantor2Map);

        resultMap.put("guarantorList", guarantorList);

        // 房产抵押情况
        resultMap.put("housePledgeList", housePledgeList);

        // 车辆质押情况
        resultMap.put("carPledgeList", carPledgeList);

        resultMap.put("reviewCounselorComment", "");
        resultMap.put("reviewRiskComment", "");
        resultMap.put("unionReviewComment1", "");
        resultMap.put("unionReviewComment2", "");
        resultMap.put("reviewManagerComment", "");

        return resultMap;
    }

}
